<!DOCTYPE html>
<html class="x-admin-sm">

<head>
    <meta charset="UTF-8">
    <title>场地考试成绩列表</title>
    <meta name="renderer" content="webkit">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <meta name="viewport"
        content="width=device-width,user-scalable=yes, minimum-scale=0.4, initial-scale=0.8,target-densitydpi=low-dpi" />
    <link rel="stylesheet" href="../css/font.css">
    <link rel="stylesheet" href="../css/iconfont.css">
    <link rel="stylesheet" href="../lib/layui/css/layui.css" media="all">

    <link rel="stylesheet" href="../css/xadmin.css">
    <script src="../lib/layui/layui.js" charset="utf-8"></script>
    <script type="text/javascript" src="../js/xadmin.js"></script>
    <script src="../js/base.js"></script>
    <!-- 让IE8/9支持媒体查询，从而兼容栅格 -->
    <!--[if lt IE 9]>
    <script src="https://cdn.staticfile.org/html5shiv/r29/html5.min.js"></script>
    <script src="https://cdn.staticfile.org/respond.js/1.4.2/respond.min.js"></script>
    <![endif]-->
    <style>
        tr td,
        tr th {
            text-align: center !important;
            border: none !important;
        }

        .layui-laydate-content tr td {
            border-bottom: none !important;
            border-top: none !important;
        }

        tr td {
            border-bottom: 1px solid #eee !important;
            border-top: 1px solid #eee !important;
        }

        .search.active {
            background: #3DB6FE;
            color: #fff;
        }

        .search.active:hover {
            color: #fff !important;
        }
    </style>
</head>

<body>
    <div class="layui-fluid">
        <div class="layui-row layui-col-space15">
            <div class="layui-col-md12">
                <div class="layui-card" style="display: flex;justify-content: space-between;">
                    <div class="layui-card-body ">
                        <blockquote class="layui-elem-quote" style="border:0;font-size: 18px;color: #000;">场地考试成绩列表
                        </blockquote>
                    </div>
                    <div class="layui-card-body " style="display: flex;">
                        <!--                    <blockquote style="cursor: pointer" class="layui-elem-quote"-->
                        <!--                                onclick="xadmin.open('新增广告','add_advertisement.html',600,500)"><i-->
                        <!--                            class="layui-icon">&#xe654;</i>新增广告-->
                        <!--                    </blockquote>-->
                        <blockquote style="cursor: pointer" class="layui-elem-quote"
                            onclick="xadmin.open('导入项目','import_pro.html',600,400)"><i class="iconfont">&#xe635;</i>导入
                        </blockquote>
                    </div>
                </div>
            </div>
            <div class="layui-col-md12">
                <div class="layui-card">
                    <!-- <div class="layui-card-header">数据统计</div> -->
                    <div class="layui-fluid">
                        <div class="layui-row layui-col-space15">
                            <div class="layui-col-md12">
                                <div class="layui-card-body " style="display: flex;justify-content:space-between">
                                    <form class="layui-form" action="">
                                        <!-- <label>真实姓名</label> -->
                                        <!-- <div class="layui-inline layui-show-xs-block" style="width:120px">
                                            <input class="layui-input" id="name" placeholder="请输入真实姓名" type="text">
                                        </div> -->
                                        <div class="layui-inline layui-show-xs-block" style="width:120px">
                                            <input class="layui-input" id="age" placeholder="请输入年龄" type="text">
                                        </div>
                                        <!-- 市/区联动 -->
                                        <div class="layui-inline layui-show-xs-block" style="width: 120px;">
                                            <select id="s_province" name="s_province" lay-filter="s_province">
                                            </select>
                                        </div>
                                        <div class="layui-inline layui-show-xs-block" style="width: 120px;">
                                            <select id="s_city" name="s_city" lay-filter="s_city">
                                            </select>
                                        </div>
                                        <div class="layui-inline layui-show-xs-block" style="width: 120px;">
                                            <select name="sex" id="sex" lay-filter="sex" lay-search>
                                                <option value="">请选择性别</option>
                                                <option value="1">男</option>
                                                <option value="2">女</option>
                                            </select>
                                        </div>
                                        <div class="layui-inline layui-show-xs-block"
                                            style="margin-left: 5px;width: 120px;">
                                            <input id="startTime" name="startTime" placeholder="考试起始时间"
                                                class="layui-input">
                                        </div>
                                        <div class="layui-inline layui-show-xs-block"
                                            style="margin-left: 5px;width: 120px;">
                                            <input id="endTime" name="endTime" placeholder="考试结束时间" class="layui-input">
                                        </div>
                                        <div class="layui-inline layui-show-xs-block">
                                            <button class="layui-btn search" data-type="reload" lay-filter="add">搜索
                                            </button>
                                        </div>
                                    </form>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
            <div class="layui-card-body layui-table-body layui-table-main">
                <div class="layui-inline layui-show-xs-block">
                    <button data-type="reload" class="layui-btn search search1 active">1级
                    </button>
                </div>
                <div class="layui-inline layui-show-xs-block">
                    <button data-type="reload" class="layui-btn search search2">2级
                    </button>
                </div>
                <div class="layui-inline layui-show-xs-block">
                    <button data-type="reload" class="layui-btn search search3">3级
                    </button>
                </div>
                <div class="layui-inline layui-show-xs-block">
                    <button data-type="reload" class="layui-btn search search4">4级
                    </button>
                </div>
                <div class="layui-inline layui-show-xs-block">
                    <button data-type="reload" class="layui-btn search search5">5级
                    </button>
                </div>
                <div class="layui-inline layui-show-xs-block">
                    <button data-type="reload" class="layui-btn search search6">6级
                    </button>
                </div>
                <div class="layui-inline layui-show-xs-block">
                    <button data-type="reload" class="layui-btn search search7">7级
                    </button>
                </div>
                <div class="layui-inline layui-show-xs-block">
                    <button data-type="reload" class="layui-btn search search8">8级
                    </button>
                </div>
                <div class="layui-inline layui-show-xs-block">
                    <button data-type="reload" class="layui-btn search search9">9级
                    </button>
                </div>
                <div class="layui-inline layui-show-xs-block">
                    <button data-type="reload" class="layui-btn search search10">10级
                    </button>
                </div>
                <!-- 表格部分开始 -->
                <table id="fieldExamination_table" lay-filter="test" lay-data="{id: 'testReload'}"></table>
                <script type="text/html" id="barDemo">
                    <a lay-event="del" class="btn_a layui-btn layui-btn-danger layui-btn-xs">删除</a>
                </script>
                <!-- 表格结束 -->
            </div>
        </div>
    </div>
    </div>
</body>

</html>
<script src="../js/area2.js"></script>
<script>
    _init_area(); //市区联动初始函数
    layui.use(['table', 'form', ['laydate']], function () {
        var table = layui.table;
        var form = layui.form;
        var laydate = layui.laydate;

        var index = layer.load(1); //添加laoding,0-2两种方式

        form.on('select(s_province)', function (data) {
            change(1);
            form.render('select');
        });
        form.on('select(s_city)', function (data) {
            form.render('select');
        });

        var date1 = laydate.render({
            elem: '#startTime',
            type: 'date'
        })
        var date2 = laydate.render({
            elem: '#endTime',
            type: 'date'
        })

        $(".search1").on("click", function () {
            $(".search").removeClass("active")
            $(this).addClass("active")
            var ins1 = table.render({
                elem: '#fieldExamination_table', //指定原始表格元素选择器（推荐id选择器）
                // height: 600,
                width: "100%",
                // 附加参数，post token
                where: {
                    'level': 1
                },
                loading: true,
                method: 'post',
                url: getFieldExaminationPage, //数据接口
                page: true, //开启分页
                // toolbar: 'default', //开启工具栏，此处显示默认图标
                cols: [
                    [ //表头
                        // { type: 'checkbox', fixed: 'left' },
                        {
                            field: 'id',
                            title: 'ID',
                            width: 100
                        },
                        {
                            field: 'name',
                            title: '姓名',
                            width: 100
                        },
                        {
                            field: 'idCard',
                            title: '身份证号',
                            width: 100
                        },
                        {
                            field: 'examinationTime',
                            title: '考试时间',
                            width: 100
                        },
                        {
                            field: 'examinationAddress',
                            title: '考试地点',
                            width: 100
                        },
                        {
                            field: 'sprint',
                            title: '专项综合障碍跑',
                            width: 200
                        },
                        {
                            field: 'standingLongJump',
                            title: '踢挡板接球转身后的（挡板）二过一后一脚球射门',
                            width: 300
                        },
                        {
                            field: 'isAdopt',
                            title: '是否通过',
                            width: 100,
                            templet: function (d) {
                                if (d.isAdopt == "1") {
                                    return "通过";
                                } else if (d.isAdopt == "2") {
                                    return "未通过";
                                }
                            }
                        },
                        {
                            field: 'level',
                            title: '申请等级',
                            width: 100,
                            templet: function (d) {
                                if (d.level == "1") {
                                    return "一级";
                                } else if (d.level == "2") {
                                    return "二级";
                                } else if (d.level == "3") {
                                    return "三级";
                                } else if (d.level == "4") {
                                    return "四级";
                                } else if (d.level == "5") {
                                    return "五级";
                                } else if (d.level == "6") {
                                    return "六级";
                                } else if (d.level == "7") {
                                    return "七级";
                                } else if (d.level == "8") {
                                    return "八级";
                                } else if (d.level == "9") {
                                    return "九级";
                                } else if (d.level == "10") {
                                    return "十级";
                                } else {
                                    return "";
                                }
                            }
                        },
                        {
                            field: 'teacherName',
                            title: "考核老师名称",
                            width: 100
                        },
                        {
                            field: 'teacherTel',
                            title: "考核老师联系电话",
                            width: 100
                        },
                        {
                            fixed: 'right',
                            title: "操作",
                            width: 100,
                            align: 'center',
                            toolbar: '#barDemo'
                        }
                    ]
                ],
                id: 'testReload',
                done: function (res) {
                    if (res.msg == "2") {
                        parent.window.location.href = getRequestPrefix() +
                            "/footBallAdmin/login.html"
                    }
                    layer.close(index)
                }
            });

        })
        $(".search2").on("click", function () {
            $(".search").removeClass("active")
            $(this).addClass("active")
            var ins1 = table.render({
                elem: '#fieldExamination_table', //指定原始表格元素选择器（推荐id选择器）
                // height: 600,
                width: "100%",
                // 附加参数，post token
                where: {
                    'level': 2
                },
                loading: true,
                method: 'post',
                url: getFieldExaminationPage, //数据接口
                page: true, //开启分页
                // toolbar: 'default', //开启工具栏，此处显示默认图标
                cols: [
                    [ //表头
                        // { type: 'checkbox', fixed: 'left' },
                        {
                            field: 'id',
                            title: 'ID',
                            width: 100
                        },
                        {
                            field: 'name',
                            title: '姓名',
                            width: 100
                        },
                        {
                            field: 'idCard',
                            title: '身份证号',
                            width: 100
                        },
                        {
                            field: 'examinationTime',
                            title: '考试时间',
                            width: 100
                        },
                        {
                            field: 'examinationAddress',
                            title: '考试地点',
                            width: 100
                        },
                        {
                            field: 'sprint',
                            title: '专项综合障碍跑',
                            width: 200
                        },
                        {
                            field: 'standingLongJump',
                            title: '球门两侧分别过标志物踢挡板后的一脚球射门',
                            width: 200
                        },
                        {
                            field: 'isAdopt',
                            title: '是否通过',
                            width: 100,
                            templet: function (d) {
                                if (d.isAdopt == "1") {
                                    return "通过";
                                } else if (d.isAdopt == "2") {
                                    return "未通过";
                                }
                            }
                        },
                        {
                            field: 'level',
                            title: '申请等级',
                            width: 100,
                            templet: function (d) {
                                if (d.level == "1") {
                                    return "一级";
                                } else if (d.level == "2") {
                                    return "二级";
                                } else if (d.level == "3") {
                                    return "三级";
                                } else if (d.level == "4") {
                                    return "四级";
                                } else if (d.level == "5") {
                                    return "五级";
                                } else if (d.level == "6") {
                                    return "六级";
                                } else if (d.level == "7") {
                                    return "七级";
                                } else if (d.level == "8") {
                                    return "八级";
                                } else if (d.level == "9") {
                                    return "九级";
                                } else if (d.level == "10") {
                                    return "十级";
                                } else {
                                    return "";
                                }
                            }
                        },
                        {
                            field: 'teacherName',
                            title: "考核老师名称",
                            width: 100
                        },
                        {
                            field: 'teacherTel',
                            title: "考核老师联系电话",
                            width: 100
                        },
                        {
                            fixed: 'right',
                            title: "操作",
                            width: 100,
                            align: 'center',
                            toolbar: '#barDemo'
                        }
                    ]
                ],
                id: 'testReload',
                done: function (res) {
                    if (res.msg == "2") {
                        parent.window.location.href = getRequestPrefix() +
                            "/footBallAdmin/login.html"
                    }
                    layer.close(index)
                }
            });

        })
        $(".search3").on("click", function () {
            $(".search").removeClass("active")
            $(this).addClass("active")
            var ins1 = table.render({
                elem: '#fieldExamination_table', //指定原始表格元素选择器（推荐id选择器）
                // height: 600,
                width: "100%",
                // 附加参数，post token
                where: {
                    'level': 3
                },
                loading: true,
                method: 'post',
                url: getFieldExaminationPage, //数据接口
                page: true, //开启分页
                // toolbar: 'default', //开启工具栏，此处显示默认图标
                cols: [
                    [ //表头
                        // { type: 'checkbox', fixed: 'left' },
                        {
                            field: 'id',
                            title: 'ID',
                            width: 100
                        },
                        {
                            field: 'name',
                            title: '姓名',
                            width: 100
                        },
                        {
                            field: 'idCard',
                            title: '身份证号',
                            width: 100
                        },
                        {
                            field: 'examinationTime',
                            title: '考试时间',
                            width: 100
                        },
                        {
                            field: 'examinationAddress',
                            title: '考试地点',
                            width: 100
                        },
                        {
                            field: 'sprint',
                            title: '专项正方形冲刺跑',
                            width: 200
                        },
                        {
                            field: 'standingLongJump',
                            title: '正面过标志物后踢挡板后两脚球射门',
                            width: 200
                        },
                        {
                            field: 'isAdopt',
                            title: '是否通过',
                            width: 100,
                            templet: function (d) {
                                if (d.isAdopt == "1") {
                                    return "通过";
                                } else if (d.isAdopt == "2") {
                                    return "未通过";
                                }
                            }
                        },
                        {
                            field: 'level',
                            title: '申请等级',
                            width: 100,
                            templet: function (d) {
                                if (d.level == "1") {
                                    return "一级";
                                } else if (d.level == "2") {
                                    return "二级";
                                } else if (d.level == "3") {
                                    return "三级";
                                } else if (d.level == "4") {
                                    return "四级";
                                } else if (d.level == "5") {
                                    return "五级";
                                } else if (d.level == "6") {
                                    return "六级";
                                } else if (d.level == "7") {
                                    return "七级";
                                } else if (d.level == "8") {
                                    return "八级";
                                } else if (d.level == "9") {
                                    return "九级";
                                } else if (d.level == "10") {
                                    return "十级";
                                } else {
                                    return "";
                                }
                            }
                        },
                        {
                            field: 'teacherName',
                            title: "考核老师名称",
                            width: 100
                        },
                        {
                            field: 'teacherTel',
                            title: "考核老师联系电话",
                            width: 100
                        },
                        {
                            fixed: 'right',
                            title: "操作",
                            width: 100,
                            align: 'center',
                            toolbar: '#barDemo'
                        }
                    ]
                ],
                id: 'testReload',
                done: function (res) {
                    if (res.msg == "2") {
                        parent.window.location.href = getRequestPrefix() +
                            "/footBallAdmin/login.html"
                    }
                    layer.close(index)
                }
            });

        })
        $(".search4").on("click", function () {
            $(".search").removeClass("active")
            $(this).addClass("active")
            var ins1 = table.render({
                elem: '#fieldExamination_table', //指定原始表格元素选择器（推荐id选择器）
                // height: 600,
                width: "100%",
                // 附加参数，post token
                where: {
                    'level': 4
                },
                loading: true,
                method: 'post',
                url: getFieldExaminationPage, //数据接口
                page: true, //开启分页
                // toolbar: 'default', //开启工具栏，此处显示默认图标
                cols: [
                    [ //表头
                        // { type: 'checkbox', fixed: 'left' },
                        {
                            field: 'id',
                            title: 'ID',
                            width: 100
                        },
                        {
                            field: 'name',
                            title: '姓名',
                            width: 100
                        },
                        {
                            field: 'idCard',
                            title: '身份证号',
                            width: 100
                        },
                        {
                            field: 'examinationTime',
                            title: '考试时间',
                            width: 100
                        },
                        {
                            field: 'examinationAddress',
                            title: '考试地点',
                            width: 100
                        },
                        {
                            field: 'sprint',
                            title: '专项“T”型跑',
                            width: 100
                        },
                        {
                            field: 'standingLongJump',
                            title: '带球“T”型跑',
                            width: 100
                        },
                        {
                            field: 'longRun',
                            title: '踢挡板传接球转身',
                            width: 200
                        },
                        {
                            field: 'shotPut',
                            title: '定点快速运球踢挡板反弹到指定区域后两脚射门',
                            width: 200
                        },
                        {
                            field: 'isAdopt',
                            title: '是否通过',
                            width: 100,
                            templet: function (d) {
                                if (d.isAdopt == "1") {
                                    return "通过";
                                } else if (d.isAdopt == "2") {
                                    return "未通过";
                                }
                            }
                        },
                        {
                            field: 'level',
                            title: '申请等级',
                            width: 100,
                            templet: function (d) {
                                if (d.level == "1") {
                                    return "一级";
                                } else if (d.level == "2") {
                                    return "二级";
                                } else if (d.level == "3") {
                                    return "三级";
                                } else if (d.level == "4") {
                                    return "四级";
                                } else if (d.level == "5") {
                                    return "五级";
                                } else if (d.level == "6") {
                                    return "六级";
                                } else if (d.level == "7") {
                                    return "七级";
                                } else if (d.level == "8") {
                                    return "八级";
                                } else if (d.level == "9") {
                                    return "九级";
                                } else if (d.level == "10") {
                                    return "十级";
                                } else {
                                    return "";
                                }
                            }
                        },
                        {
                            field: 'teacherName',
                            title: "考核老师名称",
                            width: 100
                        },
                        {
                            field: 'teacherTel',
                            title: "考核老师联系电话",
                            width: 100
                        },
                        {
                            fixed: 'right',
                            title: "操作",
                            width: 100,
                            align: 'center',
                            toolbar: '#barDemo'
                        }
                    ]
                ],
                id: 'testReload',
                done: function (res) {
                    if (res.msg == "2") {
                        parent.window.location.href = getRequestPrefix() +
                            "/footBallAdmin/login.html"
                    }
                    layer.close(index)
                }
            });

        })
        $(".search5").on("click", function () {
            $(".search").removeClass("active")
            $(this).addClass("active")
            var ins1 = table.render({
                elem: '#fieldExamination_table', //指定原始表格元素选择器（推荐id选择器）
                // height: 600,
                width: "100%",
                // 附加参数，post token
                where: {
                    'level': 5
                },
                loading: true,
                method: 'post',
                url: getFieldExaminationPage, //数据接口
                page: true, //开启分页
                // toolbar: 'default', //开启工具栏，此处显示默认图标
                cols: [
                    [ //表头
                        // { type: 'checkbox', fixed: 'left' },
                        {
                            field: 'id',
                            title: 'ID',
                            width: 100
                        },
                        {
                            field: 'name',
                            title: '姓名',
                            width: 100
                        },
                        {
                            field: 'idCard',
                            title: '身份证号',
                            width: 100
                        },
                        {
                            field: 'examinationTime',
                            title: '考试时间',
                            width: 100
                        },
                        {
                            field: 'examinationAddress',
                            title: '考试地点',
                            width: 100
                        },
                        {
                            field: 'sprint',
                            title: '专项折返跑',
                            width: 100
                        },
                        {
                            field: 'standingLongJump',
                            title: '带球折线向前',
                            width: 200
                        },
                        {
                            field: 'longRun',
                            title: '定点距离一脚连续传接',
                            width: 200
                        },
                        {
                            field: 'shotPut',
                            title: '定点带球到指定区域射门',
                            width: 200
                        },
                        {
                            field: 'isAdopt',
                            title: '是否通过',
                            width: 100,
                            templet: function (d) {
                                if (d.isAdopt == "1") {
                                    return "通过";
                                } else if (d.isAdopt == "2") {
                                    return "未通过";
                                }
                            }
                        },
                        {
                            field: 'level',
                            title: '申请等级',
                            width: 100,
                            templet: function (d) {
                                if (d.level == "1") {
                                    return "一级";
                                } else if (d.level == "2") {
                                    return "二级";
                                } else if (d.level == "3") {
                                    return "三级";
                                } else if (d.level == "4") {
                                    return "四级";
                                } else if (d.level == "5") {
                                    return "五级";
                                } else if (d.level == "6") {
                                    return "六级";
                                } else if (d.level == "7") {
                                    return "七级";
                                } else if (d.level == "8") {
                                    return "八级";
                                } else if (d.level == "9") {
                                    return "九级";
                                } else if (d.level == "10") {
                                    return "十级";
                                } else {
                                    return "";
                                }
                            }
                        },
                        {
                            field: 'teacherName',
                            title: "考核老师名称",
                            width: 100
                        },
                        {
                            field: 'teacherTel',
                            title: "考核老师联系电话",
                            width: 100
                        },
                        {
                            fixed: 'right',
                            title: "操作",
                            width: 100,
                            align: 'center',
                            toolbar: '#barDemo'
                        }
                    ]
                ],
                id: 'testReload',
                done: function (res) {
                    if (res.msg == "2") {
                        parent.window.location.href = getRequestPrefix() +
                            "/footBallAdmin/login.html"
                    }
                    layer.close(index)
                }
            });

        })
        $(".search6").on("click", function () {
            $(".search").removeClass("active")
            $(this).addClass("active")
            var ins1 = table.render({
                elem: '#fieldExamination_table', //指定原始表格元素选择器（推荐id选择器）
                // height: 600,
                width: "100%",
                // 附加参数，post token
                where: {
                    'level': 6
                },
                loading: true,
                method: 'post',
                url: getFieldExaminationPage, //数据接口
                page: true, //开启分页
                // toolbar: 'default', //开启工具栏，此处显示默认图标
                cols: [
                    [ //表头
                        // { type: 'checkbox', fixed: 'left' },
                        {
                            field: 'id',
                            title: 'ID',
                            width: 100
                        },
                        {
                            field: 'name',
                            title: '姓名',
                            width: 100
                        },
                        {
                            field: 'idCard',
                            title: '身份证号',
                            width: 100
                        },
                        {
                            field: 'examinationTime',
                            title: '考试时间',
                            width: 100
                        },
                        {
                            field: 'examinationAddress',
                            title: '考试地点',
                            width: 100
                        },
                        {
                            field: 'sprint',
                            title: '专项折返跑',
                            width: 200
                        },
                        {
                            field: 'standingLongJump',
                            title: '带球方形折线跑',
                            width: 200
                        },
                        {
                            field: 'longRun',
                            title: '定点传接球',
                            width: 200
                        },
                        {
                            field: 'shotPut',
                            title: '定点射门中上角',
                            width: 200
                        },
                        {
                            field: 'isAdopt',
                            title: '是否通过',
                            width: 100,
                            templet: function (d) {
                                if (d.isAdopt == "1") {
                                    return "通过";
                                } else if (d.isAdopt == "2") {
                                    return "未通过";
                                }
                            }
                        },
                        {
                            field: 'level',
                            title: '申请等级',
                            width: 100,
                            templet: function (d) {
                                if (d.level == "1") {
                                    return "一级";
                                } else if (d.level == "2") {
                                    return "二级";
                                } else if (d.level == "3") {
                                    return "三级";
                                } else if (d.level == "4") {
                                    return "四级";
                                } else if (d.level == "5") {
                                    return "五级";
                                } else if (d.level == "6") {
                                    return "六级";
                                } else if (d.level == "7") {
                                    return "七级";
                                } else if (d.level == "8") {
                                    return "八级";
                                } else if (d.level == "9") {
                                    return "九级";
                                } else if (d.level == "10") {
                                    return "十级";
                                } else {
                                    return "";
                                }
                            }
                        },
                        {
                            field: 'teacherName',
                            title: "考核老师名称",
                            width: 100
                        },
                        {
                            field: 'teacherTel',
                            title: "考核老师联系电话",
                            width: 100
                        },
                        {
                            fixed: 'right',
                            title: "操作",
                            width: 100,
                            align: 'center',
                            toolbar: '#barDemo'
                        }
                    ]
                ],
                id: 'testReload',
                done: function (res) {
                    if (res.msg == "2") {
                        parent.window.location.href = getRequestPrefix() +
                            "/footBallAdmin/login.html"
                    }
                    layer.close(index)
                }
            });

        })
        $(".search7").on("click", function () {
            $(".search").removeClass("active")
            $(this).addClass("active")
            var ins1 = table.render({
                elem: '#fieldExamination_table', //指定原始表格元素选择器（推荐id选择器）
                // height: 600,
                width: "100%",
                // 附加参数，post token
                where: {
                    'level': 7
                },
                loading: true,
                method: 'post',
                url: getFieldExaminationPage, //数据接口
                page: true, //开启分页
                // toolbar: 'default', //开启工具栏，此处显示默认图标
                cols: [
                    [ //表头
                        // { type: 'checkbox', fixed: 'left' },
                        {
                            field: 'id',
                            title: 'ID',
                            width: 100
                        },
                        {
                            field: 'name',
                            title: '姓名',
                            width: 100
                        },
                        {
                            field: 'idCard',
                            title: '身份证号',
                            width: 100
                        },
                        {
                            field: 'examinationTime',
                            title: '考试时间',
                            width: 100
                        },
                        {
                            field: 'examinationAddress',
                            title: '考试地点',
                            width: 100
                        },
                        {
                            field: 'sprint',
                            title: '专项绕杆跑',
                            width: 100
                        },
                        {
                            field: 'standingLongJump',
                            title: '带球快速绕杆',
                            width: 200
                        },
                        {
                            field: 'longRun',
                            title: '定点射门',
                            width: 200
                        },
                        {
                            field: 'isAdopt',
                            title: '是否通过',
                            width: 100,
                            templet: function (d) {
                                if (d.isAdopt == "1") {
                                    return "通过";
                                } else if (d.isAdopt == "2") {
                                    return "未通过";
                                }
                            }
                        },
                        {
                            field: 'level',
                            title: '申请等级',
                            width: 100,
                            templet: function (d) {
                                if (d.level == "1") {
                                    return "一级";
                                } else if (d.level == "2") {
                                    return "二级";
                                } else if (d.level == "3") {
                                    return "三级";
                                } else if (d.level == "4") {
                                    return "四级";
                                } else if (d.level == "5") {
                                    return "五级";
                                } else if (d.level == "6") {
                                    return "六级";
                                } else if (d.level == "7") {
                                    return "七级";
                                } else if (d.level == "8") {
                                    return "八级";
                                } else if (d.level == "9") {
                                    return "九级";
                                } else if (d.level == "10") {
                                    return "十级";
                                } else {
                                    return "";
                                }
                            }
                        },
                        {
                            field: 'teacherName',
                            title: "考核老师名称",
                            width: 100
                        },
                        {
                            field: 'teacherTel',
                            title: "考核老师联系电话",
                            width: 100
                        },
                        {
                            fixed: 'right',
                            title: "操作",
                            width: 100,
                            align: 'center',
                            toolbar: '#barDemo'
                        }
                    ]
                ],
                id: 'testReload',
                done: function (res) {
                    if (res.msg == "2") {
                        parent.window.location.href = getRequestPrefix() +
                            "/footBallAdmin/login.html"
                    }
                    layer.close(index)
                }
            });

        })
        $(".search8").on("click", function () {
            $(".search").removeClass("active")
            $(this).addClass("active")
            var ins1 = table.render({
                elem: '#fieldExamination_table', //指定原始表格元素选择器（推荐id选择器）
                // height: 600,
                width: "100%",
                // 附加参数，post token
                where: {
                    'level': 8
                },
                loading: true,
                method: 'post',
                url: getFieldExaminationPage, //数据接口
                page: true, //开启分页
                // toolbar: 'default', //开启工具栏，此处显示默认图标
                cols: [
                    [ //表头
                        // { type: 'checkbox', fixed: 'left' },
                        {
                            field: 'id',
                            title: 'ID',
                            width: 100
                        },
                        {
                            field: 'name',
                            title: '姓名',
                            width: 100
                        },
                        {
                            field: 'idCard',
                            title: '身份证号',
                            width: 100
                        },
                        {
                            field: 'examinationTime',
                            title: '考试时间',
                            width: 100
                        },
                        {
                            field: 'examinationAddress',
                            title: '考试地点',
                            width: 100
                        },
                        {
                            field: 'sprint',
                            title: '505专项跑',
                            width: 100
                        },
                        {
                            field: 'standingLongJump',
                            title: '5米带球快速折返',
                            width: 200
                        },
                        {
                            field: 'longRun',
                            title: '5米脚弓推射两球门',
                            width: 200
                        },
                        {
                            field: 'isAdopt',
                            title: '是否通过',
                            width: 100,
                            templet: function (d) {
                                if (d.isAdopt == "1") {
                                    return "通过";
                                } else if (d.isAdopt == "2") {
                                    return "未通过";
                                }
                            }
                        },
                        {
                            field: 'level',
                            title: '申请等级',
                            width: 100,
                            templet: function (d) {
                                if (d.level == "1") {
                                    return "一级";
                                } else if (d.level == "2") {
                                    return "二级";
                                } else if (d.level == "3") {
                                    return "三级";
                                } else if (d.level == "4") {
                                    return "四级";
                                } else if (d.level == "5") {
                                    return "五级";
                                } else if (d.level == "6") {
                                    return "六级";
                                } else if (d.level == "7") {
                                    return "七级";
                                } else if (d.level == "8") {
                                    return "八级";
                                } else if (d.level == "9") {
                                    return "九级";
                                } else if (d.level == "10") {
                                    return "十级";
                                } else {
                                    return "";
                                }
                            }
                        },
                        {
                            field: 'teacherName',
                            title: "考核老师名称",
                            width: 100
                        },
                        {
                            field: 'teacherTel',
                            title: "考核老师联系电话",
                            width: 100
                        },
                        {
                            fixed: 'right',
                            title: "操作",
                            width: 100,
                            align: 'center',
                            toolbar: '#barDemo'
                        }
                    ]
                ],
                id: 'testReload',
                done: function (res) {
                    if (res.msg == "2") {
                        parent.window.location.href = getRequestPrefix() +
                            "/footBallAdmin/login.html"
                    }
                    layer.close(index)
                }
            });

        })
        $(".search9").on("click", function () {
            $(".search").removeClass("active")
            $(this).addClass("active")
            var ins1 = table.render({
                elem: '#fieldExamination_table', //指定原始表格元素选择器（推荐id选择器）
                // height: 600,
                width: "100%",
                // 附加参数，post token
                where: {
                    'level': 9
                },
                loading: true,
                method: 'post',
                url: getFieldExaminationPage, //数据接口
                page: true, //开启分页
                // toolbar: 'default', //开启工具栏，此处显示默认图标
                cols: [
                    [ //表头
                        // { type: 'checkbox', fixed: 'left' },
                        {
                            field: 'id',
                            title: 'ID',
                            width: 100
                        },
                        {
                            field: 'name',
                            title: '姓名',
                            width: 100
                        },
                        {
                            field: 'idCard',
                            title: '身份证号',
                            width: 100
                        },
                        {
                            field: 'examinationTime',
                            title: '考试时间',
                            width: 100
                        },
                        {
                            field: 'examinationAddress',
                            title: '考试地点',
                            width: 100
                        },

                        {
                            field: 'sprint',
                            title: '双脚连续跳',
                            width: 100
                        },
                        {
                            field: 'standingLongJump',
                            title: '10米带球进目标区域',
                            width: 200
                        },
                        {
                            field: 'longRun',
                            title: '5米脚射目标门',
                            width: 200
                        },
                        {
                            field: 'isAdopt',
                            title: '是否通过',
                            width: 100,
                            templet: function (d) {
                                if (d.isAdopt == "1") {
                                    return "通过";
                                } else if (d.isAdopt == "2") {
                                    return "未通过";
                                }
                            }
                        },
                        {
                            field: 'level',
                            title: '申请等级',
                            width: 100,
                            templet: function (d) {
                                if (d.level == "1") {
                                    return "一级";
                                } else if (d.level == "2") {
                                    return "二级";
                                } else if (d.level == "3") {
                                    return "三级";
                                } else if (d.level == "4") {
                                    return "四级";
                                } else if (d.level == "5") {
                                    return "五级";
                                } else if (d.level == "6") {
                                    return "六级";
                                } else if (d.level == "7") {
                                    return "七级";
                                } else if (d.level == "8") {
                                    return "八级";
                                } else if (d.level == "9") {
                                    return "九级";
                                } else if (d.level == "10") {
                                    return "十级";
                                } else {
                                    return "";
                                }
                            }
                        },
                        {
                            field: 'teacherName',
                            title: "考核老师名称",
                            width: 100
                        },
                        {
                            field: 'teacherTel',
                            title: "考核老师联系电话",
                            width: 100
                        },
                        {
                            fixed: 'right',
                            title: "操作",
                            width: 100,
                            align: 'center',
                            toolbar: '#barDemo'
                        }
                    ]
                ],
                id: 'testReload',
                done: function (res) {
                    if (res.msg == "2") {
                        parent.window.location.href = getRequestPrefix() +
                            "/footBallAdmin/login.html"
                    }
                    layer.close(index)
                }
            });

        })
        $(".search10").on("click", function () {
            $(".search").removeClass("active")
            $(this).addClass("active")
            var ins1 = table.render({
                elem: '#fieldExamination_table', //指定原始表格元素选择器（推荐id选择器）
                // height: 600,
                width: "100%",
                // 附加参数，post token
                where: {
                    'level': 10
                },
                loading: true,
                method: 'post',
                url: getFieldExaminationPage, //数据接口
                page: true, //开启分页
                // toolbar: 'default', //开启工具栏，此处显示默认图标
                cols: [
                    [ //表头
                        // { type: 'checkbox', fixed: 'left' },
                        {
                            field: 'id',
                            title: 'ID',
                            width: 100
                        },
                        {
                            field: 'name',
                            title: '姓名',
                            width: 100
                        },
                        {
                            field: 'idCard',
                            title: '身份证号',
                            width: 100
                        },
                        {
                            field: 'examinationTime',
                            title: '考试时间',
                            width: 100
                        },
                        {
                            field: 'examinationAddress',
                            title: '考试地点',
                            width: 100
                        },
                        {
                            field: 'sprint',
                            title: '单脚站立',
                            width: 100
                        },
                        {
                            field: 'standingLongJump',
                            title: '5米带球进目标区域',
                            width: 200
                        },
                        {
                            field: 'longRun',
                            title: '3米脚射目标门',
                            width: 200
                        },
                        {
                            field: 'isAdopt',
                            title: '是否通过',
                            width: 100,
                            templet: function (d) {
                                if (d.isAdopt == "1") {
                                    return "通过";
                                } else if (d.isAdopt == "2") {
                                    return "未通过";
                                }
                            }
                        },
                        {
                            field: 'level',
                            title: '申请等级',
                            width: 100,
                            templet: function (d) {
                                if (d.level == "1") {
                                    return "一级";
                                } else if (d.level == "2") {
                                    return "二级";
                                } else if (d.level == "3") {
                                    return "三级";
                                } else if (d.level == "4") {
                                    return "四级";
                                } else if (d.level == "5") {
                                    return "五级";
                                } else if (d.level == "6") {
                                    return "六级";
                                } else if (d.level == "7") {
                                    return "七级";
                                } else if (d.level == "8") {
                                    return "八级";
                                } else if (d.level == "9") {
                                    return "九级";
                                } else if (d.level == "10") {
                                    return "十级";
                                } else {
                                    return "";
                                }
                            }
                        },
                        {
                            field: 'teacherName',
                            title: "考核老师名称",
                            width: 100
                        },
                        {
                            field: 'teacherTel',
                            title: "考核老师联系电话",
                            width: 100
                        },
                        {
                            fixed: 'right',
                            title: "操作",
                            width: 100,
                            align: 'center',
                            toolbar: '#barDemo'
                        }
                    ]
                ],
                id: 'testReload',
                done: function (res) {
                    if (res.msg == "2") {
                        parent.window.location.href = getRequestPrefix() +
                            "/footBallAdmin/login.html"
                    }
                    layer.close(index)
                }
            });

        })

        //第一个实例
        var ins1 = table.render({
            elem: '#fieldExamination_table', //指定原始表格元素选择器（推荐id选择器）
            // height: 600,
            width: "100%",
            // 附加参数，post token
            where: {
                'level': 1
            },
            loading: true,
            method: 'post',
            url: getFieldExaminationPage, //数据接口
            page: true, //开启分页
            // toolbar: 'default', //开启工具栏，此处显示默认图标
            cols: [
                [ //表头
                    // { type: 'checkbox', fixed: 'left' },
                    {
                        field: 'id',
                        title: 'ID',
                        width: 100
                    },
                    {
                        field: 'name',
                        title: '姓名',
                        width: 100
                    },
                    {
                        field: 'idCard',
                        title: '身份证号',
                        width: 100
                    },
                    {
                        field: 'examinationTime',
                        title: '考试时间',
                        width: 100
                    },
                    {
                        field: 'examinationAddress',
                        title: '考试地点',
                        width: 100
                    },
                    {
                        field: 'sprint',
                        title: '专项综合障碍跑',
                        width: 200
                    },
                    {
                        field: 'standingLongJump',
                        title: '踢挡板接球转身后的（挡板）二过一后一脚球射门',
                        width: 300
                    },
                    {
                        field: 'isAdopt',
                        title: '是否通过',
                        width: 100,
                        templet: function (d) {
                            if (d.isAdopt == "1") {
                                return "通过";
                            } else if (d.isAdopt == "2") {
                                return "未通过";
                            }
                        }
                    },
                    {
                        field: 'level',
                        title: '申请等级',
                        width: 100,
                        templet: function (d) {
                            if (d.level == "1") {
                                return "一级";
                            } else if (d.level == "2") {
                                return "二级";
                            } else if (d.level == "3") {
                                return "三级";
                            } else if (d.level == "4") {
                                return "四级";
                            } else if (d.level == "5") {
                                return "五级";
                            } else if (d.level == "6") {
                                return "六级";
                            } else if (d.level == "7") {
                                return "七级";
                            } else if (d.level == "8") {
                                return "八级";
                            } else if (d.level == "9") {
                                return "九级";
                            } else if (d.level == "10") {
                                return "十级";
                            } else {
                                return "";
                            }
                        }
                    },
                    {
                        field: 'teacherName',
                        title: "考核老师名称",
                        width: 100
                    },
                    {
                        field: 'teacherTel',
                        title: "考核老师联系电话",
                        width: 100
                    },
                    {
                        fixed: 'right',
                        title: "操作",
                        width: 100,
                        align: 'center',
                        toolbar: '#barDemo'
                    }
                ]
            ],
            id: 'testReload',
            done: function (res) {
                if (res.msg == "2") {
                    parent.window.location.href = getRequestPrefix() + "/footBallAdmin/login.html"
                }
                layer.close(index)
            }
        });


        //头部输入框筛选功能
        active = {

            reload: function () {

                var age = $('#age');
                var city = $('#s_province').val();
                var area = $('#s_city').val();
                if (city == "地级市") {
                    city = ""
                }
                if (area == "地区") {
                    area = ""
                }
                var sex = $('#sex');
                var startTime = $('#startTime');
                var endTime = $('#endTime');
                // 执行重载（重新加载数据表格）
                table.reload('testReload', {
                    page: {
                        curr: 1 //重新从第 1 页开始
                    },
                    where: {
                        "age": age.val(),
                        "city": city,
                        "area": area,
                        "sex": sex.val(),
                        "startTime": startTime.val(),
                        "endTime": endTime.val(),
                    }
                }, 'data');
            }
        };


        //给查询添加点击事件
        $('.search').on('click', function () {
            var type = $(this).data('type');
            active[type] ? active[type].call(this) : '';
            //一定要阻止表单的默认行为（刷新）
            return false
        });


        //监听头工具栏事件


        //监听点击的按钮，获取行信息
        table.on('tool(test)', function (obj) { //注：tool 是工具条事件名，test 是 table 原始容器的属性 lay-filter="对应的值"
            //获得当前行数据
            var data = obj.data,
                layEvent = obj.event; //获得 lay-event 对应的值
            if (layEvent === "del") {
                layer.confirm('真的删除行么', function (index) { //点击确定后，才执行下面语句
                    $.ajax({
                        type: "get",
                        url: delFieldExamination,
                        data: {
                            id: data.id
                        },
                        success: function (res) {
                            if (res.msg == 0) {
                                //删除成功
                                layer.alert("删除成功")
                                // console.log(index, data);//获取行信息
                                obj.del(); //删除对应行（tr）的DOM结构
                                layer.close(index);
                                table.reload('testReload', {
                                    page: {
                                        curr: 1 //重新从第 1 页开始
                                    }
                                }, 'data');
                            } else {
                                layer.msg(res.msg)
                            }
                        }
                    })

                    //向服务端发送删除指令
                });
            }
        });


    });

    /**
     * 点击放大图片
     * @param t
     */
    function show_img(t) {
        var t = $(t).find("img");
        //页面层
        layer.open({
            type: 1,
            skin: 'layui-layer-rim', //加上边框
            area: ['70%', '80%'], //宽高
            shadeClose: true, //开启遮罩关闭
            end: function (index, layero) {
                return false;
            },
            content: '<div style="text-align:center;width:100%;height: 100%;overflow: hidden"><img src="' + $(t)
                .attr('src') + '" style="width:100%;height: 100%;display: block;margin: 0 auto;"/></div>'
        });
    }
</script>